/**
 * 功能描述
 */

define(function (require, exports, module) {
	var Form = require("form");
	var store = require("store");
	var activeUser = store.get("user");
	
    var instance = {
        initComponent: function (params, widget) {
        	var form = new Form({
				parentNode : ".J-topform",
				show : false,
				model : {
					id : "topform",
					defaultButton : false,
					layout : "3_1",
					items : [{
						name:"pkCheckIn",
						type:"hidden"
					},{
						name : "checkInImplement.groupReserve.planItemGroup.planItem.destination.name",
						type : "hidden",
						label : "目的地",
						readonly : true,
					},{
						name: "room",
						label: "房间",
						readonly : true,
					},{
						name : "checkInDate",
						type : "date",
						label : "入住日期",
						mode : "YYYY-MM-DD",
						readonly : true,
					}, {
						name : "checkOutDate",
						type : "date",
						label : "退房日期",
						mode : "YYYY-MM-DD",
						readonly : true,
					}, {
						name : "countMember",
						type : "text",
						label : "入住人数",
						readonly : true,
					}, {
						name : "checkInImplement.groupReserve.reserveDate",
						type : "hidden",
						label : "预约日期",
						mode : "YYYY-MM-DD",
						readonly : true,
					}, {
						name : "checkInImplement.groupReserve.operator.name",
						type : "hidden",
						label : "预约人",
						readonly : true,
						defaultValue:activeUser.name
					},{
						name: "roomConsumption",
						label: "房内消费",
						readonly : true,
					},{
						name: "damages",
						label: "赔偿费",
						readonly : true,
					},{
						name: "description",
						label: "备注",
						readonly : true,
					}]
				}
			});
			widget.set("topform",form);
        }
    };
    module.exports = instance;
});
